//
//  SINATeacherSelectIdentsViewController.m
//  sinashebao
//
//  Created by  androidlongs on 2017/12/29.
//  Copyright © 2017年  androidlongs. All rights reserved.
//

#import "SINATeacherSelectIdentsViewController.h"
#import "SINAUserModel.h"
#import "SINALoginViewController.h"
#import "SINANavLoginViewController.h"
#import "JPUSHService.h"

@interface SINATeacherSelectIdentsViewController ()
//身份切换
@property (weak, nonatomic) IBOutlet UIButton *selectIdentButton;
//返回
@property (weak, nonatomic) IBOutlet UIButton *backButton;

@end

@implementation SINATeacherSelectIdentsViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view from its nib.
    
    //设置lable的圆角显示
    self.selectIdentButton.layer.cornerRadius =5;
    //设置lable的边框 宽度为1
    self.selectIdentButton.layer.borderWidth=0;
    //设置lable的边框颜色
    self.selectIdentButton.layer.borderColor=[UIColor redColor].CGColor;
    //设置 显示大小范围为 border内容范围中
    self.selectIdentButton.clipsToBounds = YES;
    [self.selectIdentButton setBackgroundColor: [UIColor colorWithRed:0/255 green:198.0/255 blue:174.0/255 alpha:0.8f]];
    
    
    //设置lable的圆角显示
    self.backButton.layer.cornerRadius =5;
    //设置lable的边框 宽度为1
    self.backButton.layer.borderWidth=0;
    //设置lable的边框颜色
    self.backButton.layer.borderColor=[UIColor redColor].CGColor;
    //设置 显示大小范围为 border内容范围中
    self.backButton.clipsToBounds = YES;
    [self.backButton setBackgroundColor: [UIColor colorWithRed:0/255 green:198.0/255 blue:174.0/255 alpha:0.8f]];
}
//身份切换功能点击
- (IBAction)identSelectClickFunction:(id)sender {
    //清除用户信息
    //移除推送
    [JPUSHService setAlias:@"" completion:^(NSInteger iResCode, NSString *iAlias, NSInteger seq) {
    } seq:101];
    //登录页面
    SINALoginViewController *rootViewControll = [[SINALoginViewController alloc]init ];
    SINANavLoginViewController *homeController = [[SINANavLoginViewController alloc] initWithRootViewController:rootViewControll];
    self.view.window.rootViewController = homeController;
    [self.view.window makeKeyAndVisible];
}
//返回功能点击
- (IBAction)backClickFucniton:(id)sender {
    [self.navigationController popViewControllerAnimated:YES];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
